<%@ page contentType="text/html; charset=utf-8" language="java" import="java.sql.*" errorPage="" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<%@ page import="NegocioVO.MesaVO"%>
<%@ page import="NegocioVO.ComandaVO"%>
<%@ page import="java.util.*"%>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Facturar</title>
<style type="text/css">
#form1 h1 {
	font-family: Verdana, Geneva, sans-serif;
}
</style>
</head>

<body>

<form id="form1" name="form1" method="post" action="">



  <h2>Emitir Factura</h2>
    
  <table>
	  <tr>
			<td><b><font size="4">Plato</b></td>
			<td><b><font size="4">Cantidad</font></b></td>
			<td><b><font size="4">Precio</font></b></td>
		</tr>
	
   <%
			ComandaVO aux1;

			String id;

			List<ComandaVO> comandas = (List<ComandaVO>)request.getAttribute("comandasAbiertas");

			for (Iterator<ComandaVO> c = comandas.iterator(); c.hasNext();) {

				aux1 = c.next();
				id = String.valueOf(aux1.getIdComanda());
		%>

		<tr>
			<td><%=aux1.getPlato().getDescripcion() %>	</td>
			<td><%=aux1.getCantidad() %></td>
			<td><%=aux1.getPlato().getPrecio() %></td>
			
		</tr>

		<%
			}
		%>
  </table>
  <p>
	</p>	
	<p>
	</p>
    <label for="mediopago">Elegir Medio de Pago</label>
  <select name="mediopago" id="mediopago">
   <option value="dropdown">Seleccione medio de pago
        <option value="efectivo">Efectivo
        <option value="debito">Tarjeta de Debito
        <option value="credito">Tarjeta de Credito
    </select>
  </p>
  <p>
    <input type="submit" name="facturar" id="facturar" value="Facturar" />
  </p>
  <p>
    <label for="total">Total Factura</label>
    <input type="text" name="total" id="total" value="totalFactura" />
  </p>
</form>

</body>
</html>